package com.ufo.all.controller;


import com.ufo.all.dao.UserMapper;
import com.ufo.all.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class testController2 {


    @Autowired
    UserMapper userMapper;

    @GetMapping("/list")
    public List<User> test(){

        return userMapper.getAllUser();
    }



}
